package com.ninespace.springboot.starterdemo;

import com.ninespace.springboot.starterdemo.user.AdminUser;
import com.ninespace.springboot.starterdemo.user.AdminUserService;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.ApplicationContext;

import java.util.List;

@SpringBootApplication
@MapperScan
public class StartertestApplication {

    public static void main(String[] args) {

        ApplicationContext context=SpringApplication.run(StartertestApplication.class, args);

        AdminUserService userDao=context.getBean(AdminUserService.class);
        List<AdminUser> userList=userDao.selectUserList();
        System.out.println(userList.toString());
    }

}
